* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    display: flex;
    justify-content: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 800px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.header {
    padding: 15px;
    background-color: #2c3e50;
    color: white;
}

h1 {
    font-size: 24px;
    margin-bottom: 15px;
    text-align: center;
}

.toolbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
}

.cell-selector {
    display: flex;
    gap: 5px;
    margin-right: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 5px;
    border-radius: 5px;
}

.cell {
    width: 30px;
    height: 30px;
    border: 2px solid #7f8c8d;
    border-radius: 5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.cell.selected {
    border-color: #f39c12;
    box-shadow: 0 0 5px #f39c12;
    transform: scale(1.1);
}

.cell.empty {
    background-color: #ecf0f1;
}

.cell.generator {
    background-color: #3498db;
    position: relative;
}

.cell.generator::after {
    content: "→";
    color: white;
    font-weight: bold;
}

.cell.mover {
    background-color: #2ecc71;
    position: relative;
}

.cell.mover::after {
    content: "→";
    color: white;
    font-weight: bold;
}

.cell.rotator {
    background-color: #9b59b6;
    position: relative;
}

.cell.rotator::after {
    content: "↻";
    color: white;
    font-weight: bold;
}

.cell.push {
    background-color: #e74c3c;
    position: relative;
}

.cell.push::after {
    content: "▣";
    color: white;
    font-weight: bold;
}

.cell.wall {
    background-color: #7f8c8d;
}

.cell.trash {
    background-color: #95a5a6;
    position: relative;
}

.cell.trash::after {
    content: "✕";
    color: white;
    font-weight: bold;
}

button {
    padding: 5px 10px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

button:hover {
    background-color: #2980b9;
}

.game-container {
    padding: 20px;
    display: flex;
    justify-content: center;
}

#gameCanvas {
    border: 1px solid #ddd;
    background-color: #ecf0f1;
    cursor: crosshair;
}

.instructions {
    margin-top: 10px;
    text-align: center;
    font-size: 0.9em;
    color: #ecf0f1;
}